package com.swz.dcrm.adpter;

import android.content.Context;

import com.swz.dcrm.R;
import com.swz.dcrm.base.ViewHolder;
import com.swz.dcrm.model.CarSeries;


import java.util.List;

public class CarSeriesAdapter extends CustomAdapter<CarSeries> {
    public CarSeriesAdapter(Context context, List<CarSeries> datas) {
        super(context, R.layout.item_car_series, datas);
    }

    @Override
    protected void convert(ViewHolder holder, CarSeries carSeries, int position) {
        holder.setText(R.id.tv_car_series,carSeries.getName());
        holder.itemView.setOnClickListener(v -> {
            if(onClickListener!=null){
                onClickListener.onItemClick(carSeries);
            }
        });
    }
}
